#include "serverclient.h"

#include <poll.h>
#include <sys/socket.h>

#include <vector>
#include <map>
#include <memory>

#ifndef SERVERRUNNER_H
#define SERVERRUNNER_H

class ServerRunner {
public :
	ServerRunner() = default ;
	ServerRunner(int serverFd) ;
	void run() ;
private :
	std::vector<struct pollfd> pfds ;
	std::map< int , std::shared_ptr<ServerClient> > clients ;
	char buffer[BUFSIZ + 4] ;
} ;

#endif
